|
2020-2021 Sunseeker Telemetry and Lighting System
|
#include "driverlib.h"Go to the source code of this file.
Functions | |
| void | main (void) |
| void main | ( | void | ) |
ADC10_A - Sample A11 (AVcc/2), Battery Monitor, LED OFF if AVcc < 2.3V
MSP430F550x Demo A single sample is made on A11 (AVcc/2) with reference to internal 1.5V Vref. Software sets ADC10SC to start sample and conversion - ADC10SC automatically cleared at EOC. ADC10_A internal oscillator times sample (16x) and conversion. ADC10BUSY flag is polled for EOC. If A11 (AVcc/2) < 0311h (1.15V) indicating AVcc is less 2.3V, P1.0 reset indicating a lo_Batt condition, else set. ACLK = n/a, MCLK = SMCLK = default DCO ~1.2MHz, ADC10CLK = ADC10OSC
MSP430F550x
-----------------
/|\| XIN|-
| | |
--|RST XOUT|-
| (AVcc/2) -> A11| [ Voltage source->Vcc + external pwr jumper]
| P1.0|-> LED [ON if AVcc > 2.3V]
| |
This example uses the following peripherals and I/O signals. You must review these and change as needed for your own board:
This example uses the following interrupt handlers. To use this example in your own application you must add these interrupt handlers to your vector table.
Definition at line 69 of file adc10_a_ex5_battMonitor.c.
References __delay_cycles(), __no_operation(), GPIO_setOutputHighOnPin(), and GPIO_setOutputLowOnPin().